The SetMediaDefaultDataRefIndex function allows you to specify which of a media's data references is to be accessed during an editing session.
pascal OSErr SetMediaDefaultDataRefIndex (
Media theMedia,
short index);
Before QuickTime 2.0, the Movie Toolbox did not allow the creation of tracks that have data in several files. Therefore, there was not a mechanism for controlling which data reference is affected by a media editing session. The SetMediaDefaultDataRefIndex function allows you to specify the index of the data reference to be edited. After calling this function, you can start editing that data reference by calling the BeginMediaEdits function.
The SetMediaPreferredChunkSize function allows you to specify a maximum chunk size for a media.
pascal OSErr SetMediaPreferredChunkSize (
Media theMedia,
long maxChunkSize);
The term chunk refers to the collection of sample data that is added to a movie when you call the AddMediaSample function. When QuickTime loads a movie for playback, it loads the data a chunk at a time. Consequently, both the size and number of chunks in a movie can affect playback performance. The toolbox tries to optimize playback performance by consolidating adjacent sample references into a single chunk (up to the limit you prescribe with this function).
The GetMediaPreferredChunkSize function allows you to retrieve the maximum chunk size for a media.
pascal OSErr GetMediaPreferredChunkSize (
Media theMedia,
long *maxChunkSize);
| Previous | Chapter Contents | Chapter Top | Next |